//
//  LRCCMenuItem.m
//  lineRunner_cocos2d
//
//  Created by chen jingsen on 13-1-17.
//  Copyright 2013年 __MyCompanyName__. All rights reserved.
//

#import "LRCCMenuItem.h"


@implementation LRCCMenuItem
-(void) selected
{
//    [self.normalImage setAnchorPoint:CGPointMake(0.5f, 0.5f)];
    self.normalImage.scale = 1.5f;
    
    
}

-(void) unselected
{
//    self.normalImage.scale = 1.0f;
    [self.normalImage runAction:[CCEaseElasticOut actionWithAction:[CCScaleTo actionWithDuration:0.5f scale:1.0f]]];
}

-(void) setNormalImage:(CCNode <CCRGBAProtocol>*)image
{
    [super setNormalImage:image];
    [image setAnchorPoint:CGPointMake(0.5f, 0.5f)];
    image.position = CGPointMake(image.contentSize.width*0.5, image.contentSize.height*0.5);
}

-(void) setSelectedImage:(CCNode <CCRGBAProtocol>*)image
{
    [super setSelectedImage:image];
    [image setAnchorPoint:CGPointMake(0.5f, 0.5f)];
}
@end
